import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [{
        path: '/',
        redirect: "/standby"
    },
    {
        path: '/index',
        component: () =>
            import ('../pages/index.vue'),
    },
    {
        path: '/setup',
        component: () =>
            import ('../pages/setup.vue'),
    },
    {
        path: '/center',
        component: () =>
            import ('../pages/center.vue'),
    },
    {
        path: '/book',
        component: () =>
            import ('../pages/book.vue'),
    },
    {
        path: '/bookdetail',
        component: () =>
            import ('../pages/bookdetail.vue'),
    },
    {
        path: '/standby',
        component: () =>
            import ('../pages/standby.vue'),
    },
    {
        path: '/advertise',
        component: () =>
            import ('../pages/advertise.vue'),
    },
    {
        path: '/zhangjie',
        component: () =>
            import ('../pages/zhangjie.vue'),
    },
    {
        path: '/search',
        component: () =>
            import ('../pages/search.vue'),
    },
    {
        path: '/booklist',
        component: () =>
            import ('../pages/booklist.vue'),
    },
    {
        path: '/login',
        component: () =>
            import ('../pages/login.vue'),
    },

]


const router = new VueRouter({
    mode: 'history',
    base: process.env.BASE_URL,
    routes,
    linkActiveClass: "active"
})

export default router